#include "widget2.h"
#include "ui_widget2.h"
#include "widget.h"
#include "ui_widget.h"
#include <QMovie>
#include<qrect.h>
#include<qtimer.h>
#include<QKeyEvent>
#include<QDebug>
#include<QFont>
#include<QPixmap>
#include<QMovie>
#include<qpainter.h>
#include<car.h>
#include<widget2.h>

widget2::widget2(QWidget *parent) :
    QWidget(parent),
    ui(new Ui::widget2)
{
    ui->setupUi(this);
    this->setGeometry(QRect(200,200,800,310));
    this->resize( QSize( 670, 350));

    QMovie *movie = new QMovie(":/myimg/picture/741.gif");
    ui->label->setScaledContents(true);
    ui->label->setMovie(movie);
    movie->start();
    ui->pushButton->setStyleSheet(tr("background-image: url(:/myimg/picture/666.png);"));
    ui->pushButton->setFixedSize(QPixmap(":/myimg/picture/666.png").size());
    ui->pushButton->setMask(QPixmap(":/myimg/picture/666.png").mask());
}


widget2::~widget2()
{
    delete ui;
}

void widget2::on_commandLinkButton_clicked()
{

    car*v=new car;
    v->show();
}


void widget2::on_pushButton_clicked()
{
    widget*k=new widget;
    k->show();
}

